package com.blb.dao;

import com.blb.pojo.Pet;

import java.sql.SQLException;

import com.blb.pojo.Page;
import com.blb.pojo.Pet;

import java.sql.SQLException;
import java.util.List;

public interface IPetDao {

    //根据id删除
    void delete(int id) throws SQLException, ClassNotFoundException;


    //寵物更新
    void update(Pet pet) throws SQLException, ClassNotFoundException;

    //根据宠物id获取单个宠物信息
    Pet getPetById(int id) throws Exception;

    List<Pet> selectPageByName(String name, int size , int page) throws Exception;

    int count(String name) throws SQLException, ClassNotFoundException;

    /**
     * 新增pet数据sql语句
     */

    Pet selectById(Pet pet) throws Exception;

    /**
     * 根据id
     * @param pet
     * @throws Exception
     */
    void insertPet(Pet pet) throws Exception;


}
